import { createSlice } from "@reduxjs/toolkit";
let parseResult = createSlice({
    name: "parseResult",
    initialState: {
        value: "",
        changeContent: "",
        defaultData: [],
        changeVauleList: [],
        ErrorList: []

    },
    reducers: {
        setResultValue: (state, action) => {
            state.value = action.payload
        },
        setChangeContent: (state, action) => {
            state.changeContent = action.payload
        },
        setDefaultData: (state, action) => {
            state.defaultData = JSON.parse(JSON.stringify(action.payload))
        },
        setChangeVauleList: (state, action) => {
            state.changeVauleList = JSON.parse(JSON.stringify(action.payload))
        },
        setErrorList: (state, action) => {

            state.ErrorList = JSON.parse(JSON.stringify(action.payload))
        }
    }
})
export const { setResultValue, setChangeContent, setDefaultData, setChangeVauleList, setErrorList } = parseResult.actions

export default parseResult